-
Notifications
You must be signed in to change notification settings - Fork 17
HW5 Vasekha #11
base: master
Are you sure you want to change the base?
HW5 Vasekha #11
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Код аккуратный.
Но механика игры не понятно, иногда не получается кинуть мяч, иногда мяч пропадает с экрана
private ImageView ballView; | ||
private ScoreView scoreView; | ||
private ImageView hoopView; | ||
private Button resetButton; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Может быть локальной переменной
public void incrementScore() { | ||
score++; | ||
if (score > 39) { | ||
paint.setColor(getResources().getColor(R.color.colorGold)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Цвета лучше заранее считать и тут только ставить их
starBlockMidX = starBlockWidth / 2f; | ||
starBlockMidY = h / 2f; | ||
starDiam = Math.min(starBlockMidX, starBlockMidY); | ||
paint.setColor(getResources().getColor(R.color.colorBlack)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Этот цвет можно поставить один раз
Исправила замечания, теперь мяч не исчезает, добавила пролет мяча через корзину при попадании |
Работа принята |
No description provided.